<h2>todoList</h2>
<div class="todolist">
  <div class="header">
    <label for="">todoList</label><input type="text" [(ngModel)]="keyWord" (keyup)="doAdd($event)">
  </div>
  <hr>
  <h3>待办事项</h3>
  <ul>
    <li class="list" *ngFor="let item of todoList;let key = index" >
      <div *ngIf="item.status == 0">
        <span><input type="checkbox" [(ngModel)]="item.status" (change)="checkBoxChange()"/>{{item.title}}</span>
        <button (click)="deleteDate(key)">X</button>
      </div>

    </li>
  </ul>
  <h3>已完成事项</h3>
  <ul>
    <li class="list" *ngFor="let item of todoList;let key = index">
      <div [hidden]="item.status == 0">
        <span><input type="checkbox" [(ngModel)]="item.status"/>{{item.title}}</span>
        <button (click)="deleteDate(key)">X</button>
      </div>
    </li>
  </ul>
</div>
{{todoList | json}}
